home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Borland / Borland C++ V5.02 / OWLINC.PAK / MENUGADG.H < prev    next >
C/C++ Source or Header  |  1997-05-06  |  1KB  |  56 lines

  1. //----------------------------------------------------------------------------
  2. // ObjectWindows
  3. // Copyright (c) 1995, 1997 by Borland International, All Rights Reserved
  4. //
  5. //$Revision:   10.3  $
  6. //
  7. // Definition TMenuGadget class
  8. //----------------------------------------------------------------------------
  9. #if !defined(OWL_MENUGADGET_H)
  10. #define OWL_MENUGADGET_H
  11.  
  12. #if !defined(OWL_TEXTGADG_H)
  13. # include <owl/textgadg.h>
  14. #endif
  15. #if !defined(OWL_MENU_H)
  16. # include <owl/menu.h>
  17. #endif
  18.  
  19. #if defined(BI_NAMESPACE)
  20. namespace OWL {
  21. #endif
  22.  
  23. // Generic definitions/compiler options (eg. alignment) preceeding the 
  24. // definition of classes
  25. #include <services/preclass.h>
  26.  
  27. //
  28. // class TMenuGadget
  29. // ~~~~~ ~~~~~~~~~~~
  30. class _OWLCLASS TMenuGadget : public TTextGadget {
  31.   public:
  32.     TMenuGadget(TMenu& menu, TWindow* window, int id = 0,
  33.                 TBorderStyle borderStyle = TGadget::ButtonUp,
  34.                 char far* text = 0, TFont* font = new TGadgetWindowFont);
  35.    ~TMenuGadget();
  36.  
  37.     // Override from TGadget
  38.     //
  39.     void LButtonDown(uint modKeys, TPoint& p);
  40.  
  41.   private:
  42.     TPopupMenu* PopupMenu;
  43.     TWindow*    CmdTarget;
  44. };
  45.  
  46.  
  47. // Generic definitions/compiler options (eg. alignment) following the 
  48. // definition of classes
  49. #include <services/posclass.h>
  50.  
  51. #if defined(BI_NAMESPACE)
  52. } // namespace OWL
  53. #endif
  54.  
  55. #endif  // OWL_MENUGADGET_H
  56.